package org.jackysoft.entity;


import org.jackysoft.bean.define.EntitySchemas;
import org.jackysoft.entity.base.AbstractEntity;
import org.jackysoft.util.NoSerialize;
import org.jackysoft.util.SecurityGrade;
import org.joda.time.DateTime;



public class FileItem extends AbstractEntity {
	/**
	 * 
	 */
	private static final long serialVersionUID = 8369294962124146711L;
	/** 主键 */

	protected String title;
	protected String diskBase;
	protected String realName;
	protected String imgpath;
	protected long size;
	protected String description;
	protected String deleteFlag;
	protected DateTime createTime;
	protected User owner;
	protected Boolean shared;
	protected String fileType;
	protected String openUrl;
	protected String saveUrl;
	protected String host;
	protected int port;
	protected int storeType;

	protected SecurityGrade securityGrade = SecurityGrade.内部;

	public FileItem() {
	}

	public FileItem(String realName) {
		this.realName = realName;
	}

	public FileItem(String id, String title, String fileType) {
		this.id = id;
		this.title = title;
		this.fileType = fileType;
	}

	public FileItem(String id, String title, String fileType, int storetype,
			String host, int port) {
		this(id, title, fileType);
		this.host = host;
		this.port = port;
	}

	public FileItem(String title, String diskBase, String realName,
			String fileType) {
		this.realName = realName;
		this.title = title;
		this.diskBase = diskBase;
		this.fileType = fileType;
	}

	
	public DateTime getCreateTime() {
		return createTime;
	}

	public String getDeleteFlag() {
		return deleteFlag;
	}

	public String getDescription() {
		return description;
	}

	public String getDiskBase() {
		return diskBase;
	}

	public String getFileType() {
		return fileType;
	}

	public String getHost() {
		return host;
	}

	public String getImgpath() {
		return imgpath;
	}

	public String getOpenUrl() {
		return openUrl;
	}

	/**
	 * @return the owner
	 */
	
	public User getOwner() {
		return owner;
	}

	public int getPort() {
		return port;
	}

	@NoSerialize
	
	public String getRealName() {
		return realName;
	}

	public String getSaveUrl() {
		return saveUrl;
	}

	public SecurityGrade getSecurityGrade() {
		return securityGrade;
	}

	public Boolean getShared() {
		return shared;
	}

	public long getSize() {
		return this.size;
	}

	public String getTitle() {
		return title;
	}

	public Boolean isShared() {
		return shared;
	}

	public void setCreateTime(DateTime createTime) {
		this.createTime = createTime;
	}

	public void setDeleteFlag(String deleteFlag) {
		this.deleteFlag = deleteFlag;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public void setDiskBase(String diskBase) {
		this.diskBase = diskBase;
	}

	public void setFileType(String fileType) {
		this.fileType = fileType;
	}

	public void setHost(String host) {
		this.host = host;
	}

	public void setImgpath(String imgpath) {
		this.imgpath = imgpath;
	}

	public void setOpenUrl(String openUrl) {
		this.openUrl = openUrl;
	}

	/**
	 * @param owner
	 *            the owner to set
	 */
	public void setOwner(User owner) {
		this.owner = owner;
	}

	public void setPort(int port) {
		this.port = port;
	}

	public void setRealName(String realName) {
		this.realName = realName;
	}

	public void setSaveUrl(String saveUrl) {
		this.saveUrl = saveUrl;
	}

	public void setSecurityGrade(SecurityGrade securityGrade) {
		this.securityGrade = securityGrade;
	}

	public void setShared(Boolean shared) {
		this.shared = shared;
	}

	public void setSize(long size) {
		this.size = size;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public int getStoreType() {
		return storeType;
	}

	public void setStoreType(int storeType) {
		this.storeType = storeType;
	}

}